using System.Data;
using Oracle.ManagedDataAccess.Client;

namespace Lzfy_Refund_Service.Services
{
    /// <summary>
    /// HIS DG Oracle数据库连接工厂
    /// </summary>
    public class HisDGOracleConnectionFactory : IHisDGOracleConnectionFactory
    {
        private readonly string _connectionString;

        public HisDGOracleConnectionFactory(string connectionString)
        {
            _connectionString = connectionString;
        }

        /// <summary>
        /// 创建数据库连接
        /// </summary>
        /// <returns>Oracle数据库连接</returns>
        public IDbConnection CreateConnection()
        {
            return new OracleConnection(_connectionString);
        }
    }
}